package com.loeng.module.system.service.socail;

import com.loeng.framework.common.pojo.PageResult;
import com.loeng.module.system.controller.admin.socail.vo.user.SocialUserPageReqVO;
import com.loeng.module.system.dal.dataobject.social.SocialUserDO;
import com.loeng.module.system.dal.mysql.social.SocialUserMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.validation.annotation.Validated;

import javax.annotation.Resource;

/**
 * 社交用户 Service 实现类
 * @author: loeng
 * @data: 2025/06/08 15:27
 **/
@Service
@Validated
@Slf4j
public class SocialUserServiceImpl implements SocialUserService {

    @Resource
    private SocialUserMapper socialUserMapper;

    /**
     * 获得社交用户
     *
     * @param id 编号
     * @return 社交用户
     */
    @Override
    public SocialUserDO getSocialUser(Long id) {
        return socialUserMapper.selectById(id);
    }

    /**
     * 获得社交用户分页
     *
     * @param pageVO 分页参数
     * @return 社交用户分页
     */
    @Override
    public PageResult<SocialUserDO> getSocialUserPage(SocialUserPageReqVO pageVO) {
        return socialUserMapper.selectPage(pageVO);
    }


}
